package com.ruoyi.coffee.domain;

import java.math.BigDecimal;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;
import lombok.Builder;

/**
 * 订单对象 cf_order
 *
 * @author dxj
 * @date 2025-01-08
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@TableName("cf_order")
public class Order extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long id;

    /**
     * 用户id
     */
    @Excel(name = "用户id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long userId;

    /**
     * 订单总金额
     */
    @Excel(name = "订单总金额")
    private BigDecimal totalPrice;

    /**
     * 优惠总金额
     */
    @Excel(name = "优惠总金额")
    private BigDecimal discountAmount;

    /**
     * 实际支付总金额
     */
    @Excel(name = "实际支付总金额")
    private BigDecimal actualPrice;

    /**
     * 订单总状态(1待支付、2已支付、3已完成、4已取消)
     */
    @Excel(name = "订单总状态(1待支付、2已支付、3已完成、4已取消)")
    private Integer status;

    /**
     * 支付方式(1微信2银行卡）
     */
    @Excel(name = "支付方式(1微信2银行卡）")
    private Integer paymentMethod;

    /**
     * 配送方式(1自提2外卖）
     */
    @Excel(name = "配送方式(1自提2外卖）")
    private Integer deliveryMethod;

    /**
     * 地址id
     */
    @Excel(name = "地址id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long addressId;


}
